package com.su.gulimall.order.feign;

import com.su.common.to.SkuHasStockVo;
import com.su.common.utils.R;
import com.su.gulimall.order.vo.WareSkuLockVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@FeignClient("gulimall-ware")
public interface WareFeignService {
    @RequestMapping("/ware/waresku/hasStock")
    R<List<SkuHasStockVo>> getSkuHasWare(@RequestBody List<Long> skuIds);

    @GetMapping("/ware/wareinfo/getFare")
    R getFare(@RequestParam("addrId") Long addrId);

    @PostMapping("/ware/waresku/lock/order")
    R orderLockStock(@RequestBody WareSkuLockVo vo);
}
